package com.quwan.entity;

import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.experimental.Accessors;

import javax.persistence.Id;

/**
*
*
* @author quan
* @date 2021-09-04 11:17
*/
 

@Data
@TableName(value = "chat_offline_msg")
@Accessors(chain = true)
public class ChatOfflineMsg {
    @Id
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @TableField(value = "sender_id")
    private Long senderId;

    @TableField(value = "receiver_id")
    private Long receiverId;

    /**
     * 建议使用用户唯一属性生成
     */
    @TableField(value = "session_id")
    private String sessionId;

    @TableField(value = "content")
    private String content;


    @JSONField(format = "yyyy-MM-dd HH:ss:mm")
    @TableField(value = "add_time")
    private Date addTime;
}